package com.yonyou.pmclouds.workquality.entity;

public enum WorkQualityCheckTypeWithBillTypeEnum {

    // 一般检查
    GENERAL("0","SGJL"),

    // 现场验收
    SITE_ACCEPTANCE("1","XCJC"),

    // 平行检验
    PARALLEL("2", "PXJY"),

    // 旁站记录
    SITE("3", "PZJL"),

    // 巡查检验
    PATROL("4", "XCJL"),

    // 综合验收
    COMPREHENSIVE_ACCEPTANCE("5","ZHYS"),

    // 开工条件
    CONDITION("6","KGBG");

    private String checkType;
    private String billType;

    WorkQualityCheckTypeWithBillTypeEnum(String checkType, String billType) {
        this.checkType = checkType;
        this.billType = billType;
    }

    public static String getBillType(String checkType) {
        for(WorkQualityCheckTypeWithBillTypeEnum typeWithBillTypeEnum : WorkQualityCheckTypeWithBillTypeEnum.values()) {
            if(typeWithBillTypeEnum.getCheckType().equalsIgnoreCase(checkType)) {
                return typeWithBillTypeEnum.getBillType();
            }
        }
        return null;
    }

    public String getCheckType() {
        return checkType;
    }

    public void setCheckType(String checkType) {
        this.checkType = checkType;
    }

    public String getBillType() {
        return billType;
    }

    public void setBillType(String billType) {
        this.billType = billType;
    }
}
